package com.dsp.bean;

import javax.persistence.Column; 
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.AccessType;

import com.core.util.BaseBean;

/**
 * 角色表
 * 
 * @author laker
 * @since 08/22/11
 * @version 1.0
 * 
 */
@Entity
@Table(name = "roles")
public class Role extends BaseBean {

	/**
	 * 
	 */
	private static final long serialVersionUID = 2532174840896211766L;

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY) //主键策略，数据库自动增长
	@AccessType(value = "property")
	@Column(name = "id")
	private Long id;
	@AccessType(value = "property")
	@Column(name = "name")
	private String name;

	/**
	 * @return the id
	 */
	public Long getId() {
		return id;
	}

	/**
	 * @param id
	 *            the id to set
	 */
	public void setId(Long id) {
		this.id = id;
	}

	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}

	/**
	 * @param name
	 *            the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}
}
